import request from '@/utils/request'

// 查询线下理财列表
export function listOffline(data) {
  return request({
    url: '/sys/financial/offline/page',
    method: 'post',
    data: data
  })
}
// 修改上架下架
export function changeStatus(id) {
  return request({
    url: `/sys/financial/offline/shelves/${id}`,
    method: 'put'
  })
}

// 删除
export function randomvideo(id) {
  return request({
    url: `/sys/mall-short-video/random/video`,
    method: 'get'
  })
}
// 查询线下理财详细
export function getOffline(id) {
  return request({
    url: `/sys/financial/offline/${id}`,
    method: 'get'
  })
}

// 新增线下理财
export function addOffline(data) {
  return request({
    url: '/sys/financial/offline/add',
    method: 'post',
    data: data
  })
}

// 修改线下理财
export function updateOffline(data) {
  return request({
    url: '/sys/financial/offline/edit',
    method: 'put',
    data: data
  })
}

// 删除线下理财
export function delOffline(id) {
  return request({ 
    url: `/sys/financial/offline/delete/${id}`,
    method: 'delete'
  })
}
